Skip to content

Conversation

Centril
Copy link
Contributor

@Centril Centril commented Apr 3, 2019

Successful merges:

Failed merges:

r? @ghost

Mokosha and others added 9 commits March 11, 2019 10:31
… C++'s std::nth_element (a.k.a. quickselect)

Add some more notes to the documentation:

- Mention that the median can be found if we used `len() / 2`.
- Mention that this function is usually called "kth element" in other libraries.

Address some comments in PR:

- Change wording on some of the documentation
- Change recursive function into a loop

Update name to `partition_at_index` and add convenience return values.

Address reviewer comments:

- Don't swap on each iteration when searching for min/max element.
- Add some docs about when we panic.
- Test that the sum of the lengths of the output matches the length of the input.
- Style fix for for-loop.

Address more reviewer comments

Fix Rng stuff for test

Fix doc test build

Don't run the partition_at_index test on wasm targets

Miri does not support entropy for test partition_at_index
The `InlineAsm` variant is extremely rare, and `mir::Statement` often
contributes significantly to peak memory usage.
Add 'partition_at_index/_by/_by_key' for slices.

This is an analog to C++'s std::nth_element (a.k.a. quickselect).

Corresponds to tracking bug rust-lang#55300.
…ited_again, r=KodrAus

improve worst-case performance of BTreeSet intersection v3

Variation of [rust-lang#59078](rust-lang#59078) with `Intersection` remaining a struct

r? @scottmcm
…ion-elem, r=eddyb

Remove adt_def from projections and downcasts in MIR

As part of optimizing generator layouts in MIR, we'd like to allow downcasting generators to variants which do not have a corresponding `def_id`, since they are created by the compiler.

This refactor hopes to allow that, without regressing perf.

r? @eddyb
…=pnkfelix

Shrink `mir::Statement`.

The `InlineAsm` variant is extremely rare, and `mir::Statement` often
contributes significantly to peak memory usage.
@Centril
Copy link
Contributor Author

Centril commented Apr 3, 2019

@bors r+ p=4

@bors
Copy link
Collaborator

bors commented Apr 3, 2019

📌 Commit d31d80b has been approved by Centril

@bors bors added the S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. label Apr 3, 2019
@bors
Copy link
Collaborator

bors commented Apr 3, 2019

⌛ Testing commit d31d80b with merge 546cb21...

bors added a commit that referenced this pull request Apr 3, 2019
Rollup of 4 pull requests

Successful merges:

 - #55448 (Add 'partition_at_index/_by/_by_key' for slices.)
 - #59186 (improve worst-case performance of BTreeSet intersection v3)
 - #59514 (Remove adt_def from projections and downcasts in MIR)
 - #59630 (Shrink `mir::Statement`.)

Failed merges:

r? @ghost
@bors
Copy link
Collaborator

bors commented Apr 3, 2019

☀️ Test successful - checks-travis, status-appveyor
Approved by: Centril
Pushing 546cb21 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Apr 3, 2019
@bors bors merged commit d31d80b into rust-lang:master Apr 3, 2019
matthiaskrgr added a commit to matthiaskrgr/rust-clippy that referenced this pull request Apr 3, 2019
bors added a commit to rust-lang/rust-clippy that referenced this pull request Apr 3, 2019
flip1995 added a commit to rust-lang/rust-clippy that referenced this pull request Apr 3, 2019
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Apr 9, 2019
Changes:
````
Remove force-host and explain no-prefer-dynamic
Escape a single quote in single_char_pattern hint
cargo fmt
Re-add tmp feature to compiletest
Remove libtest from deps
Re-allow clippy::identity_conversion in compiletest
Use latest compiletest-rs
Revert tests/compile-test.rs to 61aa5c9
Fix ICE in suspicious_else_formatting
use a multispan for MANY_SINGLE_CHAR_NAMES
Add missing `// run-pass` annotations to ICE tests
Remove clippy_dev as dev-dependency
NFC: fix typos
rustup rust-lang#59657
Add TransmutingNull Lint * Late Lint pass, catches:   * One liner: 0 -> null -> transmute   * One liner: std:null() -> transmute   * Const (which resolves to null) -> transmute * UI Test case for Lint * Updated test for issue 3849, because now the lint that code generated is in Clippy. * Expanded `const.rs` miri-based Constant Folding code, to cover   raw pointers
Run rustfmt
Set level of identity_conversion FP to warn
Rustup to rust-lang#58805
rustup 41316f0
Updated source to match with recent rustc `master` toolchain changes
Fix dogfood error of question_mark lint fix
Fix question_mark lint+test
use `span_lint_and_sugg` in `explicit_counter_loop`
Fix some test failures
Hacky rustup
run cargo fmt
rustup rust-lang#59096
Change explicit_counter_loop's message to add parentheses if necessary
Change explicit_counter_loop's message to reflect original variable name
cargo fmt
Add rustfix tests for mistyped_literal_suffix lint
Move some `unreadable_literal` ui tests to correct file
Add implementation for the EarlyLintPass trait into the Adding Lints documentation.
Add rust-toolchain for clippy_dev
````
@Centril Centril deleted the rollup-w5p98mc branch April 17, 2019 03:53
@Centril Centril added the rollup A PR which is a rollup label Oct 2, 2019
flip1995 pushed a commit to flip1995/rust-clippy that referenced this pull request May 5, 2020
Changes:
````
Remove force-host and explain no-prefer-dynamic
Escape a single quote in single_char_pattern hint
cargo fmt
Re-add tmp feature to compiletest
Remove libtest from deps
Re-allow clippy::identity_conversion in compiletest
Use latest compiletest-rs
Revert tests/compile-test.rs to 61aa5c9
Fix ICE in suspicious_else_formatting
use a multispan for MANY_SINGLE_CHAR_NAMES
Add missing `// run-pass` annotations to ICE tests
Remove clippy_dev as dev-dependency
NFC: fix typos
rustup rust-lang/rust#59657
Add TransmutingNull Lint * Late Lint pass, catches:   * One liner: 0 -> null -> transmute   * One liner: std:null() -> transmute   * Const (which resolves to null) -> transmute * UI Test case for Lint * Updated test for issue 3849, because now the lint that code generated is in Clippy. * Expanded `const.rs` miri-based Constant Folding code, to cover   raw pointers
Run rustfmt
Set level of identity_conversion FP to warn
Rustup to rust-lang/rust#58805
rustup 41316f0
Updated source to match with recent rustc `master` toolchain changes
Fix dogfood error of question_mark lint fix
Fix question_mark lint+test
use `span_lint_and_sugg` in `explicit_counter_loop`
Fix some test failures
Hacky rustup
run cargo fmt
rustup rust-lang/rust#59096
Change explicit_counter_loop's message to add parentheses if necessary
Change explicit_counter_loop's message to reflect original variable name
cargo fmt
Add rustfix tests for mistyped_literal_suffix lint
Move some `unreadable_literal` ui tests to correct file
Add implementation for the EarlyLintPass trait into the Adding Lints documentation.
Add rust-toolchain for clippy_dev
````
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merged-by-bors This PR was explicitly merged by bors. rollup A PR which is a rollup S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants